home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / tool_tip / tipdemo.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1995-09-06  |  57.2 KB  |  1,464 lines

  1. VERSION 2.00
  2. Begin Form frmTipDemo 
  3.    BackColor       =   &H00C0C0C0&
  4.    Caption         =   "ToolTip Demo V1.4"
  5.    ClientHeight    =   5205
  6.    ClientLeft      =   465
  7.    ClientTop       =   3030
  8.    ClientWidth     =   7890
  9.    Height          =   5895
  10.    Left            =   405
  11.    LinkTopic       =   "Form1"
  12.    ScaleHeight     =   5205
  13.    ScaleWidth      =   7890
  14.    Top             =   2400
  15.    Width           =   8010
  16.    Begin PictureBox Picture1 
  17.       Align           =   2  'Align Bottom
  18.       BackColor       =   &H00C0C0C0&
  19.       Height          =   345
  20.       Left            =   0
  21.       ScaleHeight     =   315
  22.       ScaleWidth      =   7860
  23.       TabIndex        =   25
  24.       TabStop         =   0   'False
  25.       Top             =   4860
  26.       Width           =   7890
  27.       Begin Label lblStatus 
  28.          BackStyle       =   0  'Transparent
  29.          Caption         =   "Ready"
  30.          Height          =   195
  31.          Left            =   900
  32.          TabIndex        =   26
  33.          Top             =   60
  34.          Width           =   6795
  35.       End
  36.       Begin Label Label7 
  37.          BackStyle       =   0  'Transparent
  38.          Caption         =   "Status:"
  39.          Height          =   195
  40.          Left            =   120
  41.          TabIndex        =   27
  42.          Top             =   60
  43.          Width           =   735
  44.       End
  45.    End
  46.    Begin PictureBox Picture2 
  47.       Align           =   1  'Align Top
  48.       BackColor       =   &H00C0C0C0&
  49.       Height          =   420
  50.       Left            =   0
  51.       ScaleHeight     =   390
  52.       ScaleWidth      =   7860
  53.       TabIndex        =   32
  54.       TabStop         =   0   'False
  55.       Top             =   0
  56.       Width           =   7890
  57.       Begin GSToolTip GSToolTip1 
  58.          BackColor       =   &H0080FFFF&
  59.          Delay1          =   800
  60.          FocusTracking   =   -1  'True
  61.          FontBold        =   0   'False
  62.          FontItalic      =   0   'False
  63.          FontName        =   "MS Sans Serif"
  64.          FontSize        =   8.25
  65.          FontStrikethru  =   0   'False
  66.          FontUnderline   =   0   'False
  67.          Left            =   2760
  68.          MenuTracking    =   -1  'True
  69.          MouseTracking   =   -1  'True
  70.          Shadow          =   3
  71.          ToolTips        =   2  'Use Tag as Default
  72.          Top             =   0
  73.       End
  74.       Begin ComboBox cboFontFace 
  75.          Height          =   300
  76.          Left            =   3600
  77.          Style           =   2  'Dropdown List
  78.          TabIndex        =   0
  79.          Tag             =   "Font Name:Select font name"
  80.          Top             =   45
  81.          Width           =   2055
  82.       End
  83.       Begin ComboBox cboFontSize 
  84.          Height          =   300
  85.          Left            =   5940
  86.          Style           =   2  'Dropdown List
  87.          TabIndex        =   1
  88.          Tag             =   "Font Size:Select font size"
  89.          Top             =   45
  90.          Width           =   1155
  91.       End
  92.       Begin Image Image1 
  93.          Height          =   330
  94.          Index           =   0
  95.          Left            =   120
  96.          Picture         =   TIPDEMO.FRX:0000
  97.          Tag             =   "New:Create a new document"
  98.          Top             =   30
  99.          Width           =   360
  100.       End
  101.       Begin Image Image1 
  102.          Height          =   330
  103.          Index           =   1
  104.          Left            =   480
  105.          Picture         =   TIPDEMO.FRX:0182
  106.          Tag             =   "Open:Open an existing document"
  107.          Top             =   30
  108.          Width           =   360
  109.       End
  110.       Begin Image Image1 
  111.          Height          =   330
  112.          Index           =   2
  113.          Left            =   840
  114.          Picture         =   TIPDEMO.FRX:0304
  115.          Tag             =   "Save:Save document to disk"
  116.          Top             =   30
  117.          Width           =   360
  118.       End
  119.       Begin Image Image1 
  120.          Height          =   330
  121.          Index           =   3
  122.          Left            =   1380
  123.          Picture         =   TIPDEMO.FRX:0486
  124.          Tag             =   "Cut:Cut selected text to clipboard"
  125.          Top             =   30
  126.          Width           =   360
  127.       End
  128.       Begin Image Image1 
  129.          Height          =   330
  130.          Index           =   4
  131.          Left            =   1740
  132.          Picture         =   TIPDEMO.FRX:0608
  133.          Tag             =   "Copy:Copy selected text to clipboard"
  134.          Top             =   30
  135.          Width           =   360
  136.       End
  137.       Begin Image Image1 
  138.          Height          =   330
  139.          Index           =   5
  140.          Left            =   2100
  141.          Picture         =   TIPDEMO.FRX:078A
  142.          Tag             =   "Paste:Paste clipboard contents into document"
  143.          Top             =   30
  144.          Width           =   360
  145.       End
  146.       Begin Image imgHelp 
  147.          Height          =   330
  148.          Left            =   7320
  149.          Picture         =   TIPDEMO.FRX:090C
  150.          Tag             =   "Help:Open ToolTip help file"
  151.          Top             =   30
  152.          Width           =   360
  153.       End
  154.    End
  155.    Begin GSTabFrame GSTabFrame1 
  156.       BackColor       =   &H00C0C0C0&
  157.       BufferDisplay   =   -1  'True
  158.       Caption         =   "General"
  159.       Height          =   4275
  160.       Index           =   0
  161.       Left            =   120
  162.       TabGroup        =   0
  163.       TabIndex        =   7
  164.       TabNumber       =   0
  165.       Tag             =   "General Information:Show general information about the ToolTip control."
  166.       Top             =   480
  167.       Width           =   7635
  168.       Begin Label Label2 
  169.          BackStyle       =   0  'Transparent
  170.          Caption         =   "This demonstration also includes the TabFrame control which allows you to implement tabbed dialog boxes in Visual Basic. A full demonstration of this control is available for download in the MSBASIC forum on Compuserve - see file TABFRAME.ZIP in library 17 (3rd Party Products)."
  171.          Height          =   855
  172.          Left            =   180
  173.          TabIndex        =   65
  174.          Top             =   2040
  175.          Width           =   7095
  176.       End
  177.       Begin Label Label22 
  178.          BackStyle       =   0  'Transparent
  179.          Caption         =   "If you have any comments or suggestions concerning this control then please contact Graham Cockell (Compuserve ID 100113, 2774) via e-mail or on the Compuserve MSBASIC forum."
  180.          Height          =   615
  181.          Left            =   180
  182.          TabIndex        =   66
  183.          Top             =   2940
  184.          Width           =   7035
  185.       End
  186.       Begin Label Label20 
  187.          BackStyle       =   0  'Transparent
  188.          Caption         =   "This product is distributed as shareware and registration details are provided in this demonstration and in the help file - click the help button on the toolbar."
  189.          Height          =   375
  190.          Left            =   180
  191.          TabIndex        =   67
  192.          Top             =   3660
  193.          Width           =   7155
  194.       End
  195.       Begin Label Label19 
  196.          BackStyle       =   0  'Transparent
  197.          Caption         =   "The ToolTip control allows you to quikly add MS style tool tips and a context sensitive status bar to your Visual Basic applications. In addition to supporting popup tool tip windows the control provides events for tracking mouse movements, menu selections and focus changes within your application. Examples of each of these functions can be viewed by selecting the appropriate tab by clicking it with the left mouse button."
  198.          Height          =   1215
  199.          Left            =   180
  200.          TabIndex        =   68
  201.          Top             =   780
  202.          Width           =   7155
  203.       End
  204.    End
  205.    Begin GSTabFrame GSTabFrame1 
  206.       BackColor       =   &H00C0C0C0&
  207.       BufferDisplay   =   -1  'True
  208.       Caption         =   "Registration"
  209.       FontBold        =   0   'False
  210.       FontItalic      =   0   'False
  211.       FontName        =   "MS Sans Serif"
  212.       FontSize        =   8.25
  213.       FontStrikethru  =   0   'False
  214.       FontUnderline   =   0   'False
  215.       Height          =   4275
  216.       Index           =   3
  217.       Left            =   120
  218.       TabGroup        =   0
  219.       TabIndex        =   10
  220.       TabNumber       =   3
  221.       Tag             =   "Registration Information:Show details of how to register the ToolTip control."
  222.       Top             =   480
  223.       Width           =   7635
  224.       Begin Label Label26 
  225.          BackStyle       =   0  'Transparent
  226.          Caption         =   "Registered versions will be sent out by e-mail unless otherwise specified."
  227.          Height          =   255
  228.          Left            =   300
  229.          TabIndex        =   64
  230.          Top             =   3900
  231.          Width           =   6915
  232.       End
  233.       Begin Label Label17 
  234.          BackStyle       =   0  'Transparent
  235.          Caption         =   "ENGLAND"
  236.          Height          =   195
  237.          Left            =   1200
  238.          TabIndex        =   63
  239.          Top             =   3600
  240.          Width           =   3255
  241.       End
  242.       Begin Label Label16 
  243.          BackStyle       =   0  'Transparent
  244.          Caption         =   "Derbyshire DE6 1PR"
  245.          Height          =   195
  246.          Left            =   1200
  247.          TabIndex        =   62
  248.          Top             =   3420
  249.          Width           =   3255
  250.       End
  251.       Begin Label Label15 
  252.          BackStyle       =   0  'Transparent
  253.          Caption         =   "Ashbourne"
  254.          Height          =   195
  255.          Left            =   1200
  256.          TabIndex        =   61
  257.          Top             =   3240
  258.          Width           =   3255
  259.       End
  260.       Begin Label Label14 
  261.          BackStyle       =   0  'Transparent
  262.          Caption         =   "Hognaston"
  263.          Height          =   195
  264.          Left            =   1200
  265.          TabIndex        =   60
  266.          Top             =   3060
  267.          Width           =   3255
  268.       End
  269.       Begin Label Label13 
  270.          BackStyle       =   0  'Transparent
  271.          Caption         =   "Fellsgarth House"
  272.          Height          =   195
  273.          Left            =   1200
  274.          TabIndex        =   59
  275.          Top             =   2880
  276.          Width           =   3255
  277.       End
  278.       Begin Label Label12 
  279.          BackStyle       =   0  'Transparent
  280.          Caption         =   "GC Consulting Services Ltd"
  281.          Height          =   195
  282.          Left            =   1200
  283.          TabIndex        =   58
  284.          Top             =   2700
  285.          Width           =   3255
  286.       End
  287.       Begin Label Label11 
  288.          BackStyle       =   0  'Transparent
  289.          Caption         =   "2) By sending a cheque or money order for 
  290. 25 to :"
  291.          Height          =   255
  292.          Left            =   240
  293.          TabIndex        =   57
  294.          Top             =   2400
  295.          Width           =   6795
  296.       End
  297.       Begin Label Label10 
  298.          BackStyle       =   0  'Transparent
  299.          Caption         =   "1) Through the SWREG forum on Compuserve. The fee is $29.95 and the registration ID is 2275."
  300.          Height          =   435
  301.          Left            =   240
  302.          TabIndex        =   56
  303.          Top             =   1920
  304.          Width           =   6915
  305.       End
  306.       Begin Label Label9 
  307.          BackStyle       =   0  'Transparent
  308.          Caption         =   "If you find the ToolTip control useful you can receive the full version, which may be distributed with your applications, by registering as follows :"
  309.          Height          =   435
  310.          Left            =   240
  311.          TabIndex        =   55
  312.          Top             =   1440
  313.          Width           =   6855
  314.       End
  315.       Begin Label Label8 
  316.          BackStyle       =   0  'Transparent
  317.          Caption         =   "This demonstration includes a fully functional version of the ToolTip control which may be used in the Visual Basic development environment only. It cannot be used in conjunction with an EXE file produced from Visual Basic."
  318.          Height          =   615
  319.          Left            =   240
  320.          TabIndex        =   54
  321.          Top             =   780
  322.          Width           =   7035
  323.       End
  324.    End
  325.    Begin GSTabFrame GSTabFrame1 
  326.       BackColor       =   &H00C0C0C0&
  327.       BufferDisplay   =   -1  'True
  328.       Caption         =   "Menu Tracking"
  329.       FontBold        =   0   'False
  330.       FontItalic      =   0   'False
  331.       FontName        =   "MS Sans Serif"
  332.       FontSize        =   8.25
  333.       FontStrikethru  =   0   'False
  334.       FontUnderline   =   0   'False
  335.       Height          =   4275
  336.       Index           =   6
  337.       Left            =   120
  338.       TabGroup        =   1
  339.       TabIndex        =   48
  340.       TabNumber       =   2
  341.       Tag             =   "Menu Tracking Details:Show details of menu tracking facilities provided by the ToolTip control"
  342.       Top             =   480
  343.       Width           =   7635
  344.       Begin Frame Frame3 
  345.          BackColor       =   &H00C0C0C0&
  346.          Caption         =   "MenuSelect Event"
  347.          Height          =   975
  348.          Left            =   480
  349.          TabIndex        =   76
  350.          Top             =   3060
  351.          Width           =   6495
  352.          Begin Label lblMenuCaption 
  353.             BackStyle       =   0  'Transparent
  354.             Height          =   195
  355.             Left            =   1740
  356.             TabIndex        =   80
  357.             Top             =   600
  358.             Width           =   4515
  359.          End
  360.          Begin Label lblMenuName 
  361.             BackStyle       =   0  'Transparent
  362.             Height          =   195
  363.             Left            =   1740
  364.             TabIndex        =   79
  365.             Top             =   360
  366.             Width           =   4515
  367.          End
  368.          Begin Label Label25 
  369.             BackStyle       =   0  'Transparent
  370.             Caption         =   "MenuCaption:"
  371.             Height          =   195
  372.             Index           =   1
  373.             Left            =   360
  374.             TabIndex        =   78
  375.             Top             =   600
  376.             Width           =   1275
  377.          End
  378.          Begin Label Label25 
  379.             BackStyle       =   0  'Transparent
  380.             Caption         =   "MenuName:"
  381.             Height          =   195
  382.             Index           =   0
  383.             Left            =   360
  384.             TabIndex        =   77
  385.             Top             =   360
  386.             Width           =   1275
  387.          End
  388.       End
  389.       Begin Label Label29 
  390.          BackStyle       =   0  'Transparent
  391.          Caption         =   "The box below ishows the event parameters each time a MenuSelect event is generated. Select the menus on this form and watch as they are updated. Notice that the system menu is recognised as well as the application menus."
  392.          Height          =   615
  393.          Left            =   300
  394.          TabIndex        =   83
  395.          Top             =   2220
  396.          Width           =   6915
  397.       End
  398.       Begin Label Label28 
  399.          BackStyle       =   0  'Transparent
  400.          Caption         =   "The MenuSelect event can be used to update a status bar, like the one at the bottom of this form, in order to provide the user with information about the function of the currently selected menu item."
  401.          Height          =   615
  402.          Left            =   300
  403.          TabIndex        =   82
  404.          Top             =   1560
  405.          Width           =   6915
  406.       End
  407.       Begin Label Label27 
  408.          BackStyle       =   0  'Transparent
  409.          Caption         =   "The ToolTip control tracks menu selections and generates a MenuSelect event for each item. Each ToolTip control can provide menu tracking for the form containing the control and, if it is an MDI form, for the menus on MDI child forms."
  410.          Height          =   615
  411.          Left            =   300
  412.          TabIndex        =   81
  413.          Top             =   900
  414.          Width           =   6915
  415.       End
  416.    End
  417.    Begin GSTabFrame GSTabFrame1 
  418.       BackColor       =   &H00C0C0C0&
  419.       BufferDisplay   =   -1  'True
  420.       Caption         =   "Events"
  421.       FontBold        =   0   'False
  422.       FontItalic      =   0   'False
  423.       FontName        =   "MS Sans Serif"
  424.       FontSize        =   8.25
  425.       FontStrikethru  =   0   'False
  426.       FontUnderline   =   0   'False
  427.       Height          =   4275
  428.       Index           =   2
  429.       Left            =   120
  430.       TabGroup        =   0
  431.       TabIndex        =   9
  432.       TabNumber       =   2
  433.       Tag             =   "ToolTip Events:Show details of events supported by the ToolTip control"
  434.       Top             =   480
  435.       Width           =   7635
  436.       Begin GSTabFrame GSTabFrame3 
  437.          ActiveColor     =   &H0080FFFF&
  438.          BackColor       =   &H00C0C0C0&
  439.          Caption         =   "Custom"
  440.          Height          =   3075
  441.          InactiveColor   =   &H00FFFF80&
  442.          Index           =   0
  443.          Left            =   360
  444.          Position        =   1  'Bottom
  445.          Style           =   0  '2D
  446.          TabGroup        =   0
  447.          TabIndex        =   19
  448.          TabNumber       =   0
  449.          Top             =   900
  450.          Width           =   6795
  451.          Begin ComboBox cboEventName 
  452.             Height          =   300
  453.             Left            =   1620
  454.             Sorted          =   -1  'True
  455.             Style           =   2  'Dropdown List
  456.             TabIndex        =   22
  457.             Top             =   180
  458.             Width           =   4875
  459.          End
  460.          Begin TextBox txtEventDesc 
  461.             BackColor       =   &H00FFFFFF&
  462.             Enabled         =   0   'False
  463.             Height          =   1875
  464.             Left            =   1620
  465.             MultiLine       =   -1  'True
  466.             TabIndex        =   21
  467.             Text            =   "txtEventDesc"
  468.             Top             =   660
  469.             Width           =   4875
  470.          End
  471.          Begin Label Label1 
  472.             BackStyle       =   0  'Transparent
  473.             Caption         =   "Event:"
  474.             Height          =   195
  475.             Index           =   2
  476.             Left            =   240
  477.             TabIndex        =   13
  478.             Top             =   240
  479.             Width           =   1095
  480.          End
  481.          Begin Label Label1 
  482.             BackStyle       =   0  'Transparent
  483.             Caption         =   "Description:"
  484.             Height          =   195
  485.             Index           =   3
  486.             Left            =   240
  487.             TabIndex        =   14
  488.             Top             =   660
  489.             Width           =   1095
  490.          End
  491.       End
  492.       Begin GSTabFrame GSTabFrame3 
  493.          ActiveColor     =   &H0080FFFF&
  494.          BackColor       =   &H00C0C0C0&
  495.          Caption         =   "Standard"
  496.          FontBold        =   0   'False
  497.          FontItalic      =   0   'False
  498.          FontName        =   "MS Sans Serif"
  499.          FontSize        =   8.25
  500.          FontStrikethru  =   0   'False
  501.          FontUnderline   =   0   'False
  502.          Height          =   3075
  503.          InactiveColor   =   &H00FFFF80&
  504.          Index           =   1
  505.          Left            =   360
  506.          Position        =   1  'Bottom
  507.          Style           =   0  '2D
  508.          TabGroup        =   0
  509.          TabIndex        =   20
  510.          TabNumber       =   1
  511.          Top             =   900
  512.          Width           =   6795
  513.          Begin Label Label6 
  514.             BackStyle       =   0  'Transparent
  515.             Caption         =   "There are no standard events supported by the ToolTip control."
  516.             Height          =   195
  517.             Left            =   180
  518.             TabIndex        =   50
  519.             Top             =   180
  520.             Width           =   6495
  521.          End
  522.       End
  523.    End
  524.    Begin GSTabFrame GSTabFrame1 
  525.       BackColor       =   &H00C0C0C0&
  526.       BufferDisplay   =   -1  'True
  527.       Caption         =   "Properties"
  528.       FontBold        =   0   'False
  529.       FontItalic      =   0   'False
  530.       FontName        =   "MS Sans Serif"
  531.       FontSize        =   8.25
  532.       FontStrikethru  =   0   'False
  533.       FontUnderline   =   0   'False
  534.       Height          =   4275
  535.       Index           =   1
  536.       Left            =   120
  537.       TabGroup        =   0
  538.       TabIndex        =   8
  539.       TabNumber       =   1
  540.       Tag             =   "ToolTip Properties:Show details of properties supported by the ToolTip control"
  541.       Top             =   480
  542.       Width           =   7635
  543.       Begin GSTabFrame GSTabFrame2 
  544.          ActiveColor     =   &H0080FFFF&
  545.          BackColor       =   &H00C0C0C0&
  546.          Caption         =   "Custom"
  547.          Height          =   3075
  548.          InactiveColor   =   &H00FFFF80&
  549.          Index           =   0
  550.          Left            =   360
  551.          Position        =   1  'Bottom
  552.          Style           =   0  '2D
  553.          TabGroup        =   0
  554.          TabIndex        =   15
  555.          TabNumber       =   0
  556.          Top             =   900
  557.          Width           =   6795
  558.          Begin TextBox txtpropDesc 
  559.             BackColor       =   &H00FFFFFF&
  560.             Enabled         =   0   'False
  561.             Height          =   1875
  562.             Left            =   1620
  563.             MultiLine       =   -1  'True
  564.             TabIndex        =   11
  565.             Text            =   "txtPropDesc"
  566.             Top             =   660
  567.             Width           =   4875
  568.          End
  569.          Begin ComboBox cboPropName 
  570.             Height          =   300
  571.             Left            =   1620
  572.             Sorted          =   -1  'True
  573.             Style           =   2  'Dropdown List
  574.             TabIndex        =   12
  575.             Top             =   180
  576.             Width           =   4875
  577.          End
  578.          Begin Label Label1 
  579.             BackStyle       =   0  'Transparent
  580.             Caption         =   "Description:"
  581.             Height          =   195
  582.             Index           =   1
  583.             Left            =   240
  584.             TabIndex        =   18
  585.             Top             =   660
  586.             Width           =   1095
  587.          End
  588.          Begin Label Label1 
  589.             BackStyle       =   0  'Transparent
  590.             Caption         =   "Property:"
  591.             Height          =   195
  592.             Index           =   0
  593.             Left            =   240
  594.             TabIndex        =   17
  595.             Top             =   240
  596.             Width           =   1095
  597.          End
  598.       End
  599.       Begin GSTabFrame GSTabFrame2 
  600.          ActiveColor     =   &H0080FFFF&
  601.          BackColor       =   &H00C0C0C0&
  602.          Caption         =   "Standard"
  603.          FontBold        =   0   'False
  604.          FontItalic      =   0   'False
  605.          FontName        =   "MS Sans Serif"
  606.          FontSize        =   8.25
  607.          FontStrikethru  =   0   'False
  608.          FontUnderline   =   0   'False
  609.          Height          =   3075
  610.          InactiveColor   =   &H00FFFF80&
  611.          Index           =   1
  612.          Left            =   360
  613.          Position        =   1  'Bottom
  614.          Style           =   0  '2D
  615.          TabGroup        =   0
  616.          TabIndex        =   16
  617.          TabNumber       =   1
  618.          Top             =   900
  619.          Width           =   6795
  620.          Begin Label Label4 
  621.             BackStyle       =   0  'Transparent
  622.             Caption         =   "Name"
  623.             Height          =   195
  624.             Index           =   1
  625.             Left            =   2940
  626.             TabIndex        =   46
  627.             Top             =   1200
  628.             Width           =   1095
  629.          End
  630.          Begin Label Label5 
  631.             BackStyle       =   0  'Transparent
  632.             Caption         =   "The colour and font properties control the appearance of the tool tip popup window and the Enabled property can be used to prevent all events from being generated."
  633.             Height          =   615
  634.             Left            =   120
  635.             TabIndex        =   51
  636.             Top             =   1560
  637.             Width           =   6495
  638.          End
  639.          Begin Label Label4 
  640.             BackStyle       =   0  'Transparent
  641.             Caption         =   "FontStrikethru"
  642.             Height          =   195
  643.             Index           =   29
  644.             Left            =   1560
  645.             TabIndex        =   53
  646.             Top             =   960
  647.             Width           =   1275
  648.          End
  649.          Begin Label Label4 
  650.             BackStyle       =   0  'Transparent
  651.             Caption         =   "FontSize"
  652.             Height          =   195
  653.             Index           =   28
  654.             Left            =   1560
  655.             TabIndex        =   52
  656.             Top             =   720
  657.             Width           =   1215
  658.          End
  659.          Begin Label Label4 
  660.             BackStyle       =   0  'Transparent
  661.             Caption         =   "Top"
  662.             Height          =   195
  663.             Index           =   21
  664.             Left            =   4260
  665.             TabIndex        =   45
  666.             Top             =   720
  667.             Width           =   1095
  668.          End
  669.          Begin Label Label4 
  670.             BackStyle       =   0  'Transparent
  671.             Caption         =   "Tag"
  672.             Height          =   195
  673.             Index           =   20
  674.             Left            =   4260
  675.             TabIndex        =   44
  676.             Top             =   480
  677.             Width           =   1095
  678.          End
  679.          Begin Label Label4 
  680.             BackStyle       =   0  'Transparent
  681.             Caption         =   "Left"
  682.             Height          =   195
  683.             Index           =   16
  684.             Left            =   2940
  685.             TabIndex        =   40
  686.             Top             =   960
  687.             Width           =   1095
  688.          End
  689.          Begin Label Label4 
  690.             BackStyle       =   0  'Transparent
  691.             Caption         =   "Index"
  692.             Height          =   195
  693.             Index           =   15
  694.             Left            =   2940
  695.             TabIndex        =   39
  696.             Top             =   720
  697.             Width           =   1095
  698.          End
  699.          Begin Label Label4 
  700.             BackStyle       =   0  'Transparent
  701.             Caption         =   "ForeColor"
  702.             Height          =   195
  703.             Index           =   11
  704.             Left            =   2940
  705.             TabIndex        =   35
  706.             Top             =   480
  707.             Width           =   1095
  708.          End
  709.          Begin Label Label4 
  710.             BackStyle       =   0  'Transparent
  711.             Caption         =   "FontUnderline"
  712.             Height          =   195
  713.             Index           =   10
  714.             Left            =   1560
  715.             TabIndex        =   34
  716.             Top             =   1200
  717.             Width           =   1275
  718.          End
  719.          Begin Label Label4 
  720.             BackStyle       =   0  'Transparent
  721.             Caption         =   "FontName"
  722.             Height          =   195
  723.             Index           =   7
  724.             Left            =   1560
  725.             TabIndex        =   31
  726.             Top             =   480
  727.             Width           =   1215
  728.          End
  729.          Begin Label Label4 
  730.             BackStyle       =   0  'Transparent
  731.             Caption         =   "FontItalic"
  732.             Height          =   195
  733.             Index           =   6
  734.             Left            =   300
  735.             TabIndex        =   30
  736.             Top             =   1200
  737.             Width           =   1215
  738.          End
  739.          Begin Label Label4 
  740.             BackStyle       =   0  'Transparent
  741.             Caption         =   "FontBold"
  742.             Height          =   195
  743.             Index           =   5
  744.             Left            =   300
  745.             TabIndex        =   29
  746.             Top             =   960
  747.             Width           =   1215
  748.          End
  749.          Begin Label Label4 
  750.             BackStyle       =   0  'Transparent
  751.             Caption         =   "Enabled"
  752.             Height          =   195
  753.             Index           =   4
  754.             Left            =   300
  755.             TabIndex        =   28
  756.             Top             =   720
  757.             Width           =   1215
  758.          End
  759.          Begin Label Label4 
  760.             BackStyle       =   0  'Transparent
  761.             Caption         =   "BackColor"
  762.             Height          =   195
  763.             Index           =   0
  764.             Left            =   300
  765.             TabIndex        =   24
  766.             Top             =   480
  767.             Width           =   1215
  768.          End
  769.          Begin Label Label3 
  770.             BackStyle       =   0  'Transparent
  771.             Caption         =   "The following standard properties are supported by the ToolTip control :-"
  772.             Height          =   195
  773.             Left            =   180
  774.             TabIndex        =   23
  775.             Top             =   180
  776.             Width           =   6495
  777.          End
  778.       End
  779.    End
  780.    Begin GSTabFrame GSTabFrame1 
  781.       BackColor       =   &H00C0C0C0&
  782.       BufferDisplay   =   -1  'True
  783.       Caption         =   "Mouse Tracking"
  784.       FontBold        =   0   'False
  785.       FontItalic      =   0   'False
  786.       FontName        =   "MS Sans Serif"
  787.       FontSize        =   8.25
  788.       FontStrikethru  =   0   'False
  789.       FontUnderline   =   0   'False
  790.       Height          =   4275
  791.       Index           =   5
  792.       Left            =   120
  793.       TabGroup        =   1
  794.       TabIndex        =   33
  795.       TabNumber       =   1
  796.       Tag             =   "Mouse Tracking Details:Show details of mouse tracking facilities provided by the ToolTip control"
  797.       Top             =   480
  798.       Width           =   7635
  799.       Begin Frame Frame2 
  800.          BackColor       =   &H00C0C0C0&
  801.          Caption         =   "MouseExit Event"
  802.          Height          =   915
  803.          Left            =   3900
  804.          TabIndex        =   36
  805.          Top             =   3120
  806.          Width           =   3315
  807.          Begin Label Label18 
  808.             BackStyle       =   0  'Transparent
  809.             Caption         =   "CtlName:"
  810.             Height          =   195
  811.             Index           =   3
  812.             Left            =   240
  813.             TabIndex        =   72
  814.             Top             =   540
  815.             Width           =   855
  816.          End
  817.          Begin Label Label18 
  818.             BackStyle       =   0  'Transparent
  819.             Caption         =   "FrmName:"
  820.             Height          =   195
  821.             Index           =   2
  822.             Left            =   240
  823.             TabIndex        =   71
  824.             Top             =   300
  825.             Width           =   855
  826.          End
  827.          Begin Label lblMouseExitFrmName 
  828.             BackStyle       =   0  'Transparent
  829.             Height          =   195
  830.             Left            =   1140
  831.             TabIndex        =   37
  832.             Top             =   300
  833.             Width           =   2115
  834.          End
  835.          Begin Label lblMouseExitCtlName 
  836.             BackStyle       =   0  'Transparent
  837.             Height          =   195
  838.             Left            =   1140
  839.             TabIndex        =   38
  840.             Top             =   540
  841.             Width           =   2115
  842.          End
  843.       End
  844.       Begin Frame Frame1 
  845.          BackColor       =   &H00C0C0C0&
  846.          Caption         =   "MouseEnter Event"
  847.          Height          =   915
  848.          Left            =   300
  849.          TabIndex        =   41
  850.          Top             =   3120
  851.          Width           =   3315
  852.          Begin Label Label18 
  853.             BackStyle       =   0  'Transparent
  854.             Caption         =   "CtlName:"
  855.             Height          =   195
  856.             Index           =   1
  857.             Left            =   240
  858.             TabIndex        =   70
  859.             Top             =   540
  860.             Width           =   855
  861.          End
  862.          Begin Label Label18 
  863.             BackStyle       =   0  'Transparent
  864.             Caption         =   "FrmName:"
  865.             Height          =   195
  866.             Index           =   0
  867.             Left            =   240
  868.             TabIndex        =   69
  869.             Top             =   300
  870.             Width           =   855
  871.          End
  872.          Begin Label lblMouseEnterCtlName 
  873.             BackStyle       =   0  'Transparent
  874.             Height          =   195
  875.             Left            =   1140
  876.             TabIndex        =   42
  877.             Top             =   540
  878.             Width           =   2115
  879.          End
  880.          Begin Label lblMouseEnterFrmName 
  881.             BackStyle       =   0  'Transparent
  882.             Height          =   195
  883.             Left            =   1140
  884.             TabIndex        =   43
  885.             Top             =   300
  886.             Width           =   2115
  887.          End
  888.       End
  889.       Begin Label Label24 
  890.          BackStyle       =   0  'Transparent
  891.          Caption         =   "The boxes below show the event parameters each time a MouseEnter or MouseExit event is generated. Move the mouse around the form and watch as they are updated. Notice that each of the tabs is recognised as a separate control - the ToolTip control works with the TabFrame control to provide this functionality."
  892.          Height          =   975
  893.          Left            =   300
  894.          TabIndex        =   75
  895.          Top             =   2100
  896.          Width           =   6915
  897.       End
  898.       Begin Label Label23 
  899.          BackStyle       =   0  'Transparent
  900.          Caption         =   "The MouseEnter and MouseExit events can be used to update a status bar, like the one at the bottom of this form, in order to provide the user with information about the function of the control which the mouse is currently over."
  901.          Height          =   615
  902.          Left            =   300
  903.          TabIndex        =   74
  904.          Top             =   1440
  905.          Width           =   6915
  906.       End
  907.       Begin Label Label21 
  908.          BackStyle       =   0  'Transparent
  909.          Caption         =   "The ToolTip control tracks movement of the mouse and generates MouseEnter and MouseExit events as the cursor moves into and out of each control. A single ToolTip control can provide mouse tracking for all the forms in an application."
  910.          Height          =   615
  911.          Left            =   300
  912.          TabIndex        =   73
  913.          Top             =   780
  914.          Width           =   6915
  915.       End
  916.    End
  917.    Begin GSTabFrame GSTabFrame1 
  918.       BackColor       =   &H00C0C0C0&
  919.       BufferDisplay   =   -1  'True
  920.       Caption         =   "ToolTips"
  921.       FontBold        =   0   'False
  922.       FontItalic      =   0   'False
  923.       FontName        =   "MS Sans Serif"
  924.       FontSize        =   8.25
  925.       FontStrikethru  =   0   'False
  926.       FontUnderline   =   0   'False
  927.       Height          =   4275
  928.       Index           =   4
  929.       Left            =   120
  930.       TabGroup        =   1
  931.       TabIndex        =   47
  932.       TabNumber       =   0
  933.       Tag             =   "ToolTip Details:Show details of tool tip facilities provided by the ToolTip control"
  934.       Top             =   480
  935.       Width           =   7635
  936.       Begin Image Image2 
  937.          Height          =   420
  938.          Index           =   1
  939.          Left            =   300
  940.          Picture         =   TIPDEMO.FRX:0A8E
  941.          Tag             =   "ToolTip:Pause to show a multi-line tool tip"
  942.          Top             =   1380
  943.          Width           =   420
  944.       End
  945.       Begin Label Label36 
  946.          BackStyle       =   0  'Transparent
  947.          Caption         =   "Move the cursor over the ToolTip icon to the left to display a multi-line tool tip with a different background colour."
  948.          Height          =   435
  949.          Left            =   960
  950.          TabIndex        =   100
  951.          Top             =   1380
  952.          Width           =   6315
  953.       End
  954.       Begin Label Label35 
  955.          BackStyle       =   0  'Transparent
  956.          Caption         =   "A single ToolTip control can provide tool tips for all the forms in an application. The tool tip text can be supplied in the GetToolTip event or taken from the Tag property of the control for which the tool tip is being shown. In many cases it will be convenient to use the GetToolTip event to extract a section of the Tag property  to be used as the tool tip - see the event procedures in this demonstartion for an example of how the Tag prpoerty can be used to supply tool tips, status bar text and focus change text."
  957.          Height          =   1395
  958.          Left            =   300
  959.          TabIndex        =   99
  960.          Top             =   2700
  961.          Width           =   6915
  962.       End
  963.       Begin Label Label34 
  964.          BackStyle       =   0  'Transparent
  965.          Caption         =   "Tool tips have been made popular by the latest releases of Microsoft Word and Excel and are rapidly becoming a standard part of many major Windows applications. Together with an intelligently updated status bar they help to make an application much easier to use."
  966.          Height          =   795
  967.          Left            =   300
  968.          TabIndex        =   98
  969.          Top             =   1860
  970.          Width           =   6915
  971.       End
  972.       Begin Label Label33 
  973.          BackStyle       =   0  'Transparent
  974.          Caption         =   "Move the cursor over the ToolTip icon to the left and pause for a short while. That small popup window is a tool tip."
  975.          Height          =   435
  976.          Left            =   960
  977.          TabIndex        =   97
  978.          Top             =   900
  979.          Width           =   6195
  980.       End
  981.       Begin Image Image2 
  982.          Height          =   420
  983.          Index           =   0
  984.          Left            =   300
  985.          Picture         =   TIPDEMO.FRX:0CC8
  986.          Tag             =   "ToolTip:Pause to show a tool tip"
  987.          Top             =   900
  988.          Width           =   420
  989.       End
  990.    End
  991.    Begin GSTabFrame GSTabFrame1 
  992.       BackColor       =   &H00C0C0C0&
  993.       BufferDisplay   =   -1  'True
  994.       Caption         =   "Focus Tracking"
  995.       FontBold        =   0   'False
  996.       FontItalic      =   0   'False
  997.       FontName        =   "MS Sans Serif"
  998.       FontSize        =   8.25
  999.       FontStrikethru  =   0   'False
  1000.       FontUnderline   =   0   'False
  1001.       Height          =   4275
  1002.       Index           =   7
  1003.       Left            =   120
  1004.       TabGroup        =   1
  1005.       TabIndex        =   49
  1006.       TabNumber       =   3
  1007.       Tag             =   "Focus Tracking Details:Show details of focus tracking facilities provided by the ToolTip control"
  1008.       Top             =   480
  1009.       Width           =   7635
  1010.       Begin CommandButton Command2 
  1011.          Caption         =   "Command2"
  1012.          Height          =   375
  1013.          Left            =   4860
  1014.          TabIndex        =   5
  1015.          Tag             =   "::Click to initiate Command1"
  1016.          Top             =   2700
  1017.          Width           =   1095
  1018.       End
  1019.       Begin CheckBox Check1 
  1020.          BackColor       =   &H00C0C0C0&
  1021.          Caption         =   "Check1"
  1022.          Height          =   255
  1023.          Left            =   3660
  1024.          TabIndex        =   4
  1025.          Tag             =   "::Click to select Check1"
  1026.          Top             =   2760
  1027.          Width           =   1035
  1028.       End
  1029.       Begin CommandButton Command1 
  1030.          Caption         =   "Command1"
  1031.          Height          =   375
  1032.          Left            =   6120
  1033.          TabIndex        =   6
  1034.          Tag             =   "::Click to initiate Command2"
  1035.          Top             =   2700
  1036.          Width           =   1095
  1037.       End
  1038.       Begin TextBox Text2 
  1039.          Height          =   285
  1040.          Left            =   1920
  1041.          TabIndex        =   3
  1042.          Tag             =   "::Enter text for Text2"
  1043.          Text            =   "Text2"
  1044.          Top             =   2760
  1045.          Width           =   1455
  1046.       End
  1047.       Begin TextBox Text1 
  1048.          Height          =   285
  1049.          Left            =   300
  1050.          TabIndex        =   2
  1051.          Tag             =   "::Enter text for Text1"
  1052.          Text            =   "Text1"
  1053.          Top             =   2760
  1054.          Width           =   1335
  1055.       End
  1056.       Begin Frame Frame5 
  1057.          BackColor       =   &H00C0C0C0&
  1058.          Caption         =   "GotFocus Event"
  1059.          Height          =   915
  1060.          Left            =   300
  1061.          TabIndex        =   91
  1062.          Top             =   3120
  1063.          Width           =   3315
  1064.          Begin Label lblGotFocusFrmName 
  1065.             BackStyle       =   0  'Transparent
  1066.             Height          =   195
  1067.             Left            =   1140
  1068.             TabIndex        =   95
  1069.             Top             =   300
  1070.             Width           =   2115
  1071.          End
  1072.          Begin Label lblGotFocusCtlName 
  1073.             BackStyle       =   0  'Transparent
  1074.             Height          =   195
  1075.             Left            =   1140
  1076.             TabIndex        =   94
  1077.             Top             =   540
  1078.             Width           =   2115
  1079.          End
  1080.          Begin Label Label18 
  1081.             BackStyle       =   0  'Transparent
  1082.             Caption         =   "FrmName:"
  1083.             Height          =   195
  1084.             Index           =   7
  1085.             Left            =   240
  1086.             TabIndex        =   93
  1087.             Top             =   300
  1088.             Width           =   855
  1089.          End
  1090.          Begin Label Label18 
  1091.             BackStyle       =   0  'Transparent
  1092.             Caption         =   "CtlName:"
  1093.             Height          =   195
  1094.             Index           =   6
  1095.             Left            =   240
  1096.             TabIndex        =   92
  1097.             Top             =   540
  1098.             Width           =   855
  1099.          End
  1100.       End
  1101.       Begin Frame Frame4 
  1102.          BackColor       =   &H00C0C0C0&
  1103.          Caption         =   "LostFocus Event"
  1104.          Height          =   915
  1105.          Left            =   3900
  1106.          TabIndex        =   86
  1107.          Top             =   3120
  1108.          Width           =   3315
  1109.          Begin Label lblLostFocusCtlName 
  1110.             BackStyle       =   0  'Transparent
  1111.             Height          =   195
  1112.             Left            =   1140
  1113.             TabIndex        =   90
  1114.             Top             =   540
  1115.             Width           =   2115
  1116.          End
  1117.          Begin Label lblLostFocusFrmName 
  1118.             BackStyle       =   0  'Transparent
  1119.             Height          =   195
  1120.             Left            =   1140
  1121.             TabIndex        =   89
  1122.             Top             =   300
  1123.             Width           =   2115
  1124.          End
  1125.          Begin Label Label18 
  1126.             BackStyle       =   0  'Transparent
  1127.             Caption         =   "FrmName:"
  1128.             Height          =   195
  1129.             Index           =   5
  1130.             Left            =   240
  1131.             TabIndex        =   88
  1132.             Top             =   300
  1133.             Width           =   855
  1134.          End
  1135.          Begin Label Label18 
  1136.             BackStyle       =   0  'Transparent
  1137.             Caption         =   "CtlName:"
  1138.             Height          =   195
  1139.             Index           =   4
  1140.             Left            =   240
  1141.             TabIndex        =   87
  1142.             Top             =   540
  1143.             Width           =   855
  1144.          End
  1145.       End
  1146.       Begin Label Label32 
  1147.          BackStyle       =   0  'Transparent
  1148.          Caption         =   "The boxes below show the event parameters each time a GotFocus or LostFocus event is generated. Use the Tab key to move focus around the form and watch as they are updated."
  1149.          Height          =   615
  1150.          Left            =   300
  1151.          TabIndex        =   96
  1152.          Top             =   2100
  1153.          Width           =   6915
  1154.       End
  1155.       Begin Label Label31 
  1156.          BackStyle       =   0  'Transparent
  1157.          Caption         =   "The GotFocus and LostFocus events can be used to update a status bar, like the one at the bottom of this form, in order to provide the user with information about the function of the control which currently has the focus."
  1158.          Height          =   615
  1159.          Left            =   300
  1160.          TabIndex        =   85
  1161.          Top             =   1440
  1162.          Width           =   6915
  1163.       End
  1164.       Begin Label Label30 
  1165.          BackStyle       =   0  'Transparent
  1166.          Caption         =   "The ToolTip control tracks the control which has the input focus and generates GotFocus and LostFocus events. A single ToolTip control can provide focus tracking for all the forms in an application."
  1167.          Height          =   615
  1168.          Left            =   300
  1169.          TabIndex        =   84
  1170.          Top             =   780
  1171.          Width           =   6915
  1172.       End
  1173.    End
  1174.    Begin Menu mnuFile 
  1175.       Caption         =   "&File"
  1176.       Tag             =   "File operations"
  1177.       Begin Menu mnuFNew 
  1178.          Caption         =   "&New"
  1179.          Tag             =   "Create new document"
  1180.       End
  1181.       Begin Menu mnuFOpen 
  1182.          Caption         =   "&Open..."
  1183.          Tag             =   "Open existing file"
  1184.       End
  1185.       Begin Menu mnuFSave 
  1186.          Caption         =   "&Save"
  1187.          Tag             =   "Save file"
  1188.       End
  1189.       Begin Menu mnuFSaveAs 
  1190.          Caption         =   "Save &As..."
  1191.          Tag             =   "Save file with new filename"
  1192.       End
  1193.       Begin Menu mnuFSep1 
  1194.          Caption         =   "-"
  1195.       End
  1196.       Begin Menu mnuFExit 
  1197.          Caption         =   "E&xit"
  1198.          Tag             =   "Exit demonstartion"
  1199.       End
  1200.    End
  1201.    Begin Menu mnuEdit 
  1202.       Caption         =   "&Edit"
  1203.       Tag             =   "Clipboard operations"
  1204.       Begin Menu mnuECut 
  1205.          Caption         =   "Cu&t"
  1206.          Shortcut        =   ^X
  1207.          Tag             =   "Cut selected text to clipboard"
  1208.       End
  1209.       Begin Menu mnuECopy 
  1210.          Caption         =   "&Copy"
  1211.          Shortcut        =   ^C
  1212.          Tag             =   "Copy selected text to clipboard"
  1213.       End
  1214.       Begin Menu mnuEPaste 
  1215.          Caption         =   "&Paste"
  1216.          Shortcut        =   ^V
  1217.          Tag             =   "Paste text from clipboard"
  1218.       End
  1219.       Begin Menu mnuEDelete 
  1220.          Caption         =   "&Delete"
  1221.          Shortcut        =   {DEL}
  1222.          Tag             =   "Delete selected text"
  1223.       End
  1224.    End
  1225.    Begin Menu mnuView 
  1226.       Caption         =   "&View"
  1227.       Tag             =   "Select new tab"
  1228.       Begin Menu mnuVTab 
  1229.          Caption         =   "&General"
  1230.          Index           =   0
  1231.          Tag             =   "Show general information about ToolTip control"
  1232.       End
  1233.       Begin Menu mnuVTab 
  1234.          Caption         =   "&Properties"
  1235.          Index           =   1
  1236.          Tag             =   "Show details of ToolTip properies"
  1237.       End
  1238.       Begin Menu mnuVTab 
  1239.          Caption         =   "&Events"
  1240.          Index           =   2
  1241.          Tag             =   "Show details of ToolTip events"
  1242.       End
  1243.       Begin Menu mnuVTab 
  1244.          Caption         =   "&Registration"
  1245.          Index           =   3
  1246.          Tag             =   "How to register the ToolTip control"
  1247.       End
  1248.       Begin Menu mnuVTab 
  1249.          Caption         =   "&ToolTips"
  1250.          Index           =   4
  1251.          Tag             =   "Description of tool tip operation"
  1252.       End
  1253.       Begin Menu mnuVTab 
  1254.          Caption         =   "&Mouse Tracking"
  1255.          Index           =   5
  1256.          Tag             =   "Description of mouse tracking"
  1257.       End
  1258.       Begin Menu mnuVTab 
  1259.          Caption         =   "Me&nu Tracking"
  1260.          Index           =   6
  1261.          Tag             =   "Description of menu tracking"
  1262.       End
  1263.       Begin Menu mnuVTab 
  1264.          Caption         =   "&Focus Tracking"
  1265.          Index           =   7
  1266.          Tag             =   "Description of focus tracking"
  1267.       End
  1268.    End
  1269.    Begin Menu mnuHelp 
  1270.       Caption         =   "&Help"
  1271.       Tag             =   "Help system operations"
  1272.       Begin Menu mnuHContents 
  1273.          Caption         =   "&Contents"
  1274.          Tag             =   "Display help contents for ToolTip control"
  1275.       End
  1276.       Begin Menu mnuHSep1 
  1277.          Caption         =   "-"
  1278.       End
  1279.       Begin Menu mnuHAbout 
  1280.          Caption         =   "&About..."
  1281.          Tag             =   "Display About dialog"
  1282.       End
  1283.    End
  1284. Option Explicit
  1285. Dim sHelpFile As String
  1286. Declare Function WinHelp Lib "User" (ByVal hWnd As Integer, ByVal lpHelpFile As String, ByVal wCommand As Integer, dwData As Any) As Integer
  1287. Sub cboEventName_Click ()
  1288.     Dim EventDesc As String
  1289.     Select Case cboEventName.List(cboEventName.ListIndex)
  1290.         Case "GetToolTip"
  1291.             EventDesc = "This event is fired when a tool tip window is about to be displayed and allows the user to specify the tool tip text."
  1292.         Case "MouseEnter"
  1293.             EventDesc = "This event is fired when the mouse enters a control. The Tag property of the control which the mouse is entering is passed as a parameter and may be used to determine the text to be displayed on a status bar."
  1294.         Case "MouseExit"
  1295.             EventDesc = "This event is fired when the mouse leaves a control."
  1296.         Case "MenuSelect"
  1297.             EventDesc = "This event is fired when a menu item is selected. The Tag property of the selected menu control is passed as a parameter and may be used to determine the text to be displayed on a status bar."
  1298.         Case "GotFocus"
  1299.             EventDesc = "This event is fired when a control receives the input focus. The Tag property of the control receiving the focus is passed as a parameter and may be used to determine the text to be displayed on a status bar."
  1300.         Case "LostFocus"
  1301.             EventDesc = "This event is fired when a control loses the input focus."
  1302.     End Select
  1303.     txtEventDesc.Text = EventDesc
  1304. End Sub
  1305. Sub cboPropName_Click ()
  1306.     Dim PropDesc As String
  1307.     Select Case cboPropName.List(cboPropName.ListIndex)
  1308.         Case "About"
  1309.             PropDesc = "This property, which is only available at design time, can be used to display the About dialog which identifies the ToolTip version number."
  1310.         Case "Scope"
  1311.             PropDesc = "This property determines which controls are monitored by the ToolTip control. If set to 0 (Application) the ToolTip control monitors controls on all forms except those which contain another ToolTip control. If set to 1 (Form) the ToolTip control only monitors controls on it's own form."
  1312.         Case "ToolTips"
  1313.             PropDesc = "This property determines how tool tips are generated. If enabled the Tag property of the control for which the tool tip is being generated can be used as the default tool tip text."
  1314.         Case "Delay1, Delay2"
  1315.             PropDesc = "These properties determine how long the mouse must remian over a control before the tool tip window appears. Delay1 controls the normal delay and Delay2 controls the delay immediately after a tool tip has been displayed. Keeping Delay2 short allows users to browse a toolbar without having to wait for each new tool tip to appear."
  1316.         Case "AutoPosition"
  1317.             PropDesc = "This property controls the positioning of the tool tip window relative to the current cursor position. If set True the ToolTip control positions the tool tip window automatically according to the current cursor (e.g. arrow, I-beam). If False the user controls the position using the OffsetX and OffsetY properties."
  1318.         Case "OffsetX, OffsetY"
  1319.             PropDesc = "These properties can be used to manually control the position of the tool tip window."
  1320.         Case "Shadow"
  1321.             PropDesc = "This property controls the size of the shadow used to highlight the tool tip window."
  1322.         Case "MouseTracking"
  1323.             PropDesc = "This property is used to enable/disable the MouseEnter and MouseExit events."
  1324.         Case "MenuTracking"
  1325.             PropDesc = "This property is used to enable/disable the MenuSelect event."
  1326.         Case "FocusTracking"
  1327.             PropDesc = "This property is used to enable/disable the GotFocus and LostFocus events."
  1328.         Case "SubclassForm"
  1329.             PropDesc = "This property is used to enable/disable the subclassing of the form required to track menu activity. It is only required in special circumstances as discussed in the Help file."
  1330.         Case "ToolTipText"
  1331.             PropDesc = "This property can be used to control the display of tool tip windows directlty."
  1332.     End Select
  1333.     txtPropDesc.Text = PropDesc
  1334. End Sub
  1335. Sub Form_Load ()
  1336.     ' position in centre of screen
  1337.     Left = (Screen.Width - Width) / 2
  1338.     Top = (Screen.Height - Height) / 2
  1339.     ' get help file name
  1340.     sHelpFile = App.Path
  1341.     If Right$(sHelpFile, 1) <> "\" Then sHelpFile = sHelpFile & "\"
  1342.     sHelpFile = sHelpFile & "ToolTip.Hlp"
  1343.     ' load property combo box
  1344.     cboPropName.Clear
  1345.     cboPropName.AddItem "About"
  1346.     cboPropName.AddItem "Scope"
  1347.     cboPropName.AddItem "ToolTips"
  1348.     cboPropName.AddItem "Delay1, Delay2"
  1349.     cboPropName.AddItem "AutoPosition"
  1350.     cboPropName.AddItem "OffsetX, OffsetY"
  1351.     cboPropName.AddItem "Shadow"
  1352.     cboPropName.AddItem "MenuTracking"
  1353.     cboPropName.AddItem "MouseTracking"
  1354.     cboPropName.AddItem "FocusTracking"
  1355.     cboPropName.AddItem "SubclassForm"
  1356.     cboPropName.AddItem "ToolTipText"
  1357.     cboPropName.ListIndex = 0
  1358.     ' load event combo box
  1359.     cboEventName.Clear
  1360.     cboEventName.AddItem "GetToolTip"
  1361.     cboEventName.AddItem "MouseEnter"
  1362.     cboEventName.AddItem "MouseExit"
  1363.     cboEventName.AddItem "MenuSelect"
  1364.     cboEventName.AddItem "GotFocus"
  1365.     cboEventName.AddItem "LostFocus"
  1366.     cboEventName.ListIndex = 0
  1367.     ' initialise tab and menu
  1368.     GSTabFrame1(0).Active = True
  1369.     mnuVTab(0).Checked = True
  1370. End Sub
  1371. Sub GSTabFrame1_Activated (Index As Integer)
  1372.     mnuVTab(Index).Checked = True
  1373. End Sub
  1374. Sub GSTabFrame1_Deactivated (Index As Integer, Cancel As Integer)
  1375.     mnuVTab(Index).Checked = False
  1376. End Sub
  1377. Sub GSToolTip1_GetToolTip (FrmName As String, CtlName As String, ToolTip As String)
  1378.     Dim n As Integer
  1379.     If CtlName = "Image2(1)" Then
  1380.         GSToolTip1.BackColor = RGB(128, 255, 255)
  1381.         ToolTip = "This is a multi-line tool tip."
  1382.         ToolTip = ToolTip & Chr$(10) & "You can have as many lines"
  1383.         ToolTip = ToolTip & Chr$(10) & "as you like (within reason)."
  1384.     Else
  1385.         GSToolTip1.BackColor = RGB(255, 255, 128)
  1386.         n = InStr(ToolTip, ":")
  1387.         If n > 0 Then ToolTip = Left$(ToolTip, n - 1)
  1388.     End If
  1389. End Sub
  1390. Sub GSToolTip1_GotFocus (FrmName As String, CtlName As String, TagText As String)
  1391.     Dim n As Integer
  1392.     Dim status As String
  1393.     ' show parameters
  1394.     lblGotFocusFrmName = FrmName
  1395.     lblGotFocusCtlName = CtlName
  1396.     ' use Tag to get status bar text for control
  1397.     status = TagText
  1398.     ' strip tool tip text from start of Tag
  1399.     n = InStr(status, ":")
  1400.     If n > 0 Then status = Mid$(status, n + 1)
  1401.     ' strip status bar text from start of Tag
  1402.     n = InStr(status, ":")
  1403.     If n > 0 Then status = Mid$(status, n + 1)
  1404.     ' display focus text for this control
  1405.     If status <> "" Then lblStatus.Caption = status
  1406. End Sub
  1407. Sub GSToolTip1_LostFocus (FrmName As String, CtlName As String)
  1408.     ' show parameters
  1409.     lblLostFocusFrmName = FrmName
  1410.     lblLostFocusCtlName = CtlName
  1411.     ' restore status bar
  1412.     lblStatus.Caption = "Ready"
  1413. End Sub
  1414. Sub GSToolTip1_MenuSelect (MenuName As String, MenuCaption As String, TagText As String)
  1415.     ' show parameters
  1416.     lblMenuName = MenuName
  1417.     lblMenuCaption = MenuCaption
  1418.     ' update status bar
  1419.     If MenuName = "" Then
  1420.         lblStatus.Caption = "Ready"
  1421.     ElseIf MenuName = "System" Then
  1422.         lblStatus = "System menu: " & MenuCaption
  1423.     Else
  1424.         lblStatus = TagText
  1425.     End If
  1426. End Sub
  1427. Sub GSToolTip1_MouseEnter (FrmName As String, CtlName As String, TagText As String)
  1428.     Dim n As Integer
  1429.     Dim status As String
  1430.     ' show parameters
  1431.     lblMouseEnterFrmName = FrmName
  1432.     lblMouseEnterCtlName = CtlName
  1433.     ' use Tag to get status bar text for control
  1434.     status = TagText
  1435.     ' strip tool tip text from start of Tag
  1436.     n = InStr(status, ":")
  1437.     If n > 0 Then status = Mid$(status, n + 1)
  1438.     ' strip focus change text from end of Tag
  1439.     n = InStr(status, ":")
  1440.     If n > 0 Then status = Left$(status, n - 1)
  1441.     ' display status bar text for this control
  1442.     If status <> "" Then lblStatus.Caption = status
  1443. End Sub
  1444. Sub GSToolTip1_MouseExit (FrmName As String, CtlName As String)
  1445.     ' show parameters
  1446.     lblMouseExitFrmName = FrmName
  1447.     lblMouseExitCtlName = CtlName
  1448.     ' restore status bar
  1449.     lblStatus.Caption = "Ready"
  1450. End Sub
  1451. Sub imgHelp_Click ()
  1452.     Dim rv As Integer
  1453.     rv = WinHelp(frmTipDemo.hWnd, sHelpFile, 3, 0)
  1454. End Sub
  1455. Sub mnuFExit_Click ()
  1456.     Unload Me
  1457. End Sub
  1458. Sub mnuHContents_Click ()
  1459.     imgHelp_Click
  1460. End Sub
  1461. Sub mnuVTab_Click (Index As Integer)
  1462.     GSTabFrame1(Index).Active = True
  1463. End Sub
  1464.